package com.tjbklx1.thread.chap05.demo02;

import java.util.concurrent.ArrayBlockingQueue;

public class Table extends ArrayBlockingQueue<String> {
	private static final long serialVersionUID = 1L;

	public Table(int count) {
		super(count);
	}

	public void put(String cake) {
		try {
			super.put(cake);
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
	}

	public String take() {
		try {
			String cake = super.take();
			return cake;
		} catch (InterruptedException e) {
			e.printStackTrace();
		}
		return null;
	}
}
